package com.seventeen.monster.mq.proxy.server.proxy.consumer;

import com.seventeen.monster.common.utils.StringUtils;

/**
 * 消费类型
 *
 * @author seventeen
 */
public enum ConsumerTypes
{
    //concurrent consumer
    CONCURRENTLY,
    //orderly consumer
    ORDERLY;

    public static ConsumerTypes getByType(String type)
    {

        for (ConsumerTypes consumerTypes:ConsumerTypes.values())
        {
            if(StringUtils.equalsIgnoreCase(consumerTypes.toString(),type))
            {
                return consumerTypes;
            }
        }

        return null;
    }

}
